/** 信息 */
interface CustomerShippingDetailType {
  id: number;
  customerShippingId: string;
  customerId: string;
  shippingPerson: string;
  shippingMobile: string;
  shippingAddressDetail: string;
  shippingProvince: string | null;
  shippingProvinceId: string | null;
  delFlag: string;
  defaultFlag: string;
  createTime: number;
  modifyTime: number | null;
}

/** 客户资质 */
interface CustomerQualificationType {
  id: number;
  customerQualificationId: string;
  customerId: string;
  qualificationType: string;
  effectiveDate: string | null;
  expiredDate: string | null;
  qualificationImg: string;
  expFlag: string;
  delFlag: string;
  createTime: string;
  enableFlag: string | null;
  customerName: string | null;
}

export type customerInfoType = {
  customerId: string;
  customerName: string;
  account: string;
  invoiceTitle: string | null;
  taxpayerId: string;
  registeredAddress: string;
  registeredPhone: string | null;
  depositBank: string;
  bankAccount: string;
  token: string;
  customerShippingDetailList: CustomerShippingDetailType[];
  customerQualificationList: CustomerQualificationType[];
  customerCatList: any[];
  reminder: string;
};

type CustomerType = {
  customer: customerInfoType;
};

/** 注册提交类型 */
export type PostData = {
  [key: string]: any; // 添加索引签名
  customerName: string; // 企业名称
  organizingInstitutionCode: string; // 组织机构代码
  businessLicense: { url: string }[]; // 营业执照
  businessCardStartDate?: string; // 开始时间
  businessCardEndDate?: string; // 结束时间
  medicalInstitution: { url: string }[]; // 医疗机构执业许可
  institutionCardStartDate?: string; // 开始时间
  institutionCardEndDate?: string; // 结束时间
  legalPersonName: string; // 法人姓名
  legalPersonIdNumber: string; // 法人身份证号
  legalPersonCardPictureObverse: { url: string }[]; // 法人身份证正面
  legalPersonCardPictureReverse: { url: string }[]; // 法人身份证反面
  legalPersonCardStartDate?: string; // 开始时间
  legalPersonCardEndDate?: string; // 开始时间
  contactMan: string; // 联系人
  contactPhone: string; // 联系人电话
  registeredAddress: string; // 注册地址
  taxpayerId: string; // 纳税人识别号
  depositBank: string; // 开户行
  bankAccount: string; // 银行账户
  account: string; // 登录手机号
  password: string; // 登录密码
  againPassword?: string; // 确认密码
  checked: boolean; // 隐私同意
};

/** 登录用户信息 */
export type LoginResultType = {
  userName: string;
  password: string;
};

export type { CustomerType };
